﻿using Entity;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;

namespace Reopsitroy
{
    public interface IBaseRepsitory<TEntity>
        where TEntity : class
    {
        TEntity Insert(TEntity entity);
        int Delete(int id);
        int DeleteAll(int[] idList);
        IQueryable<TEntity> Queryable();
        List<TEntity> QueryList();
        List<TEntity> QueryList(Expression<Func<TEntity, bool>> condition);
        TEntity QueryFirst(int id);
        TEntity Update(TEntity entity);
    }
}